package com.tz.util;

import com.tz.WebAppConfig;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

/**
 * Created by Administrator on 16-7-25.
 */
public class MyAcUtil {

    static {
        System.out.println("静态代码块 run....");
        ac = new AnnotationConfigApplicationContext(WebAppConfig.class);
    }

    private static ApplicationContext ac;

    public static ApplicationContext getAc() {
        return ac;
    }

}
